From 37d62149bbbfae23364be411fdd822337f47cc69 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Javier=20Jard=C3=B3n?= Date: Wed, 11 Aug 2010 23:10:21 +0200 Subject: [PATCH] gtk/gtkinfobar.c: use accessor functions to access GtkWidget --- gtk/gtkinfobar.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/gtk/gtkinfobar.c b/gtk/gtkinfobar.c index 08de226266..7de08fb5a5 100644 --- a/gtk/gtkinfobar.c +++ b/gtk/gtkinfobar.c @@ -310,21 +310,22 @@ gtk_info_bar_expose (GtkWidget *widget, if (priv->message_type != GTK_MESSAGE_OTHER) { + GtkAllocation allocation; const char *detail; detail = type_detail[priv->message_type]; - gtk_paint_box (widget->style, - widget->window, + gtk_widget_get_allocation (widget, &allocation); + + gtk_paint_box (gtk_widget_get_style (widget), + gtk_widget_get_window (widget), GTK_STATE_NORMAL, GTK_SHADOW_OUT, NULL, widget, detail, - widget->allocation.x, - widget->allocation.y, - widget->allocation.width, - widget->allocation.height); + allocation.x, allocation.y, + allocation.width, allocation.height); } if (GTK_WIDGET_CLASS (gtk_info_bar_parent_class)->expose_event) @@ -569,9 +570,9 @@ gtk_info_bar_update_colors (GtkInfoBar *info_bar) } } - if (!gdk_color_equal (bg, &widget->style->bg[GTK_STATE_NORMAL])) + if (!gdk_color_equal (bg, &style->bg[GTK_STATE_NORMAL])) gtk_widget_modify_bg (widget, GTK_STATE_NORMAL, bg); - if (!gdk_color_equal (fg, &widget->style->fg[GTK_STATE_NORMAL])) + if (!gdk_color_equal (fg, &style->fg[GTK_STATE_NORMAL])) gtk_widget_modify_fg (widget, GTK_STATE_NORMAL, fg); } -- 2.30.2